/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.jili.ubert.code.client2server;

import com.baidu.bjf.remoting.protobuf.Codec;
import com.baidu.bjf.remoting.protobuf.ProtobufProxy;
import com.baidu.bjf.remoting.protobuf.annotation.Protobuf;
import java.io.IOException;
import java.util.Date;

/**
 *
 * @author ChengJiLi
 */
public class NewOrderS {
    @Protobuf
    private int orderId;
     private Date timeStamp;
     @Protobuf
     private String accountCode;
     @Protobuf
     private String dealerUserId;
     private Date submitTime;
     private Date tradeDate;
     private Date dateTime;
     @Protobuf
     private String mac;
     @Protobuf
     private String ip;
     @Protobuf
     private String obj;
     @Protobuf
     private Character marketCode;
     @Protobuf
     private String classCode;
     @Protobuf
     private Character bs;
     @Protobuf
     private Character openClose;
     @Protobuf
     private Character priceType;
     @Protobuf
     private Float orderPrice;
     @Protobuf
     private Integer orderQty;
     @Protobuf
     private Character hedgeFlag;
     @Protobuf
     private String posId;
     @Protobuf
     private String closeType;
     private Integer basketId;
     private Integer basketTatol;
     private Integer seqnum;
     private String ownUserId;
     private String alterUserId;
     private Date createTime;

    public NewOrderS() {
    }

	
    public NewOrderS(int orderId, String accountCode, String dealerUserId, Date submitTime, Date tradeDate, Date dateTime, String obj) {
        this.orderId = orderId;
        this.accountCode = accountCode;
        this.dealerUserId = dealerUserId;
        this.submitTime = submitTime;
        this.tradeDate = tradeDate;
        this.dateTime = dateTime;
        this.obj = obj;
    }
    public NewOrderS(int orderId, String accountCode, String dealerUserId, Date submitTime, Date tradeDate, Date dateTime, String mac, String ip, String obj, Character marketCode, String classCode, Character bs, Character openClose, Character priceType, Float orderPrice, Integer orderQty, Character hedgeFlag, String posId, String closeType, Integer basketId, Integer basketTatol, Integer seqnum, String ownUserId, String alterUserId, Date createTime) {
       this.orderId = orderId;
       this.accountCode = accountCode;
       this.dealerUserId = dealerUserId;
       this.submitTime = submitTime;
       this.tradeDate = tradeDate;
       this.dateTime = dateTime;
       this.mac = mac;
       this.ip = ip;
       this.obj = obj;
       this.marketCode = marketCode;
       this.classCode = classCode;
       this.bs = bs;
       this.openClose = openClose;
       this.priceType = priceType;
       this.orderPrice = orderPrice;
       this.orderQty = orderQty;
       this.hedgeFlag = hedgeFlag;
       this.posId = posId;
       this.closeType = closeType;
       this.basketId = basketId;
       this.basketTatol = basketTatol;
       this.seqnum = seqnum;
       this.ownUserId = ownUserId;
       this.alterUserId = alterUserId;
       this.createTime = createTime;
    }
   
    
    @Override
    public String toString(){
        return "NewOrder:orderId :"+ getOrderId()+
       ",accountCode :"+ getAccountCode()+
       ",dealerUserId :"+ getDealerUserId()+
       ",submitTime :"+ submitTime+
       ",tradeDate :"+ tradeDate+
       ",mac :"+ getMac()+
       ",ip :"+ getIp()+
       ",obj :"+ getObj()+
       ",bs :"+ getBs()+
       ",openClose :"+ getOpenClose()+
       ",priceType :"+ getPriceType()+
       ",orderPrice :"+ getOrderPrice()+
       ",orderQty :"+ getOrderQty()+
       ",hedgeFlag :"+ getHedgeFlag()+
       ",marketCode :"+ marketCode+
       ",classCode :"+ getClassCode()+
       ",posId :"+ getPosId()+
       ",ownUserId :"+ getOwnUserId();
        
    }
    public byte[] EnCode(NewOrderS msg) throws IOException{
        Codec<NewOrderS> Lcode = ProtobufProxy.create(NewOrderS.class);
        return Lcode.encode(msg);
    }
    public NewOrderS DeCode(byte[] data) throws IOException{
        Codec<NewOrderS> Lcode = ProtobufProxy.create(NewOrderS.class);
        return Lcode.decode(data);
        
    }

    /**
     * @return the orderId
     */
    public int getOrderId() {
        return orderId;
    }

    /**
     * @return the timeStamp
     */
    public Date getTimeStamp() {
        return timeStamp;
    }

    /**
     * @return the accountCode
     */
    public String getAccountCode() {
        return accountCode;
    }

    /**
     * @return the dealerUserId
     */
    public String getDealerUserId() {
        return dealerUserId;
    }

    /**
     * @return the submitTime
     */
    public Date getSubmitTime() {
        return submitTime;
    }

    /**
     * @return the tradeDate
     */
    public Date getTradeDate() {
        return tradeDate;
    }

    /**
     * @return the dateTime
     */
    public Date getDateTime() {
        return dateTime;
    }

    /**
     * @return the mac
     */
    public String getMac() {
        return mac;
    }

    /**
     * @return the ip
     */
    public String getIp() {
        return ip;
    }

    /**
     * @return the obj
     */
    public String getObj() {
        return obj;
    }

    /**
     * @return the marketCode
     */
    public Character getMarketCode() {
        return marketCode;
    }

    /**
     * @return the classCode
     */
    public String getClassCode() {
        return classCode;
    }

    /**
     * @return the bs
     */
    public Character getBs() {
        return bs;
    }

    /**
     * @return the openClose
     */
    public Character getOpenClose() {
        return openClose;
    }

    /**
     * @return the priceType
     */
    public Character getPriceType() {
        return priceType;
    }

    /**
     * @return the orderPrice
     */
    public Float getOrderPrice() {
        return orderPrice;
    }

    /**
     * @return the orderQty
     */
    public Integer getOrderQty() {
        return orderQty;
    }

    /**
     * @return the hedgeFlag
     */
    public Character getHedgeFlag() {
        return hedgeFlag;
    }

    /**
     * @return the posId
     */
    public String getPosId() {
        return posId;
    }

    /**
     * @return the closeType
     */
    public String getCloseType() {
        return closeType;
    }

    /**
     * @return the basketId
     */
    public Integer getBasketId() {
        return basketId;
    }

    /**
     * @return the basketTatol
     */
    public Integer getBasketTatol() {
        return basketTatol;
    }

    /**
     * @return the seqnum
     */
    public Integer getSeqnum() {
        return seqnum;
    }

    /**
     * @return the ownUserId
     */
    public String getOwnUserId() {
        return ownUserId;
    }

    /**
     * @return the alterUserId
     */
    public String getAlterUserId() {
        return alterUserId;
    }

    /**
     * @return the createTime
     */
    public Date getCreateTime() {
        return createTime;
    }
}
